<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        html {
            font-size: 62.5%;
        }

        .item1 {
            font-size: 1rem;
        }

        .item2 {
            font-size: 16px;
        }

        .item4 {
            font-size: 10px;
        }

        .item4-ch1 {
            font-size: 1rem;
        }
    </style>
</head>
<body>
<div class="item1">hello world</div>
<div class="item3">hello world</div>
<div class="item4">
    <div class="item4-ch1">hello world</div>
</div>
<div class="item2">hello world</div>
<script>
    // 1rem = 16px
    // 为了计算方便，给外界设置了font-size: 62.5%，将字体缩小了;然后1rem = 16px * 62.5% = 10px
</script>
</body>
</html>